A network generally includes a number of network devices including, for example, routers, bridges, and switches. Each networked device includes a file referred to as an “image” or “binary image” that is stored in memory and runs on the processor. The image includes information about the functionality of the hardware. Also, each network device needs to be configured in order to operate properly. A configuration file is usually stored on the device.
A network administrator or developer can generally be referred to as the user. A user is generally a person who is responsible for uploading new images, changing configurations, maintaining the network and the network devices and/or adding new features to the network or network devices. From time to time, the user may need to upgrade a firmware version or to reconfigure a network device when changes in the network occur. In the case of upgrades or reconfigurations, as well as in situations in which bugs exist in the running firmware, a “fatal” state may occur. A fatal state is the state the network device enters when running firmware performs an illegal operation due to image corruption, misconfiguration or implementation bugs.
When a fatal action occurs, the device may enter debug mode. Most network devices have the ability to enter debug mode when the fatal action occurs. Debug mode gives the user the opportunity to check the configuration state or memory/register contents to find out what caused the problem. All this can be done via a serial port with the use of console commands. Usually, the user is able to change the image to the proper one or reconfigure the device while in debug mode.
After a fatal action, the user can usually only reset the device. The device will always enter debug mode if problem exists in loaded firmware. To resolve such a problem, the user usually must force a recovery mode or launch an application that properly configures the device. Both approaches have disadvantages.
Entering recovery mode sometimes is needless and undesirable. Recovery mode is a state of the network device that is forced to reset the firmware version and configuration to the factory default. The user typically loses the device configuration so the part of the network depending on that device falls into inoperative state. After a fatal action, launching any configuring application—i.e. a console command interface—in most cases is impossible. Only debug commands work properly.